package cn.itcast.exception;

import cn.itcast.response.ResponseResult;

/**
 * @Description:
 * @Version: V1.0
 */
public class BusinessException extends RuntimeException{

    private ResponseResult responseResult; // 保存错误信息统一响应

    public BusinessException(ResponseResult responseResult) {
        // 记录日志...  发邮件给对应的开发人员...
        this.responseResult = responseResult;
    }

    // 提供get方法即可
    public ResponseResult getResponseResult() {
        return responseResult;
    }
}